package com.lai;

import java.util.Scanner;

public class mark {
    public static void main(String[] args) {
        double[] arr = new double[6];
        Scanner sc = new Scanner(System.in);
        System.out.println("请输入六位导师的分数：");
        for (int i = 0;i<arr.length;i++){
            arr[i] = sc.nextInt();
        }
        double max=arr[0] , min=arr[0];
        for (int j = 1; j < arr.length; j++) {
            if(arr[j]>max){
                max = arr[j];
            }else if(arr[j]<min){
                min = arr[j];
            }
        }
        double number = 0;
        for (int x = 0; x < 6; x++) {
            number = arr[x] + number;
        }
        number = (number - max - min)/4;
        System.out.println(number);
    }
}
